<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<base href="http://localhost/shopex/" />
<link rel="stylesheet" type="text/css" href="App/Admin/Common/images/metinfo.css" />
<script type="text/javascript" src="App/Admin/Common/ckeditor/ckeditor.js"></script>

<link rel="stylesheet" href="App/Admin/Common/css/common.css">
   <link rel="stylesheet" href="App/Admin/Common/css/newslist.css">
   
   <script type="text/javascript" src="App/Admin/Common/js/jquery.min.js"></script>
   <script type="text/javascript" src="App/Admin/Common/js/colResizable-1.3.min.js"></script>
   <script type="text/javascript" src="App/Admin/Common/js/common.js"></script>
   
   <script type="text/javascript">
      $(function(){  
        $(".list_table").colResizable({
          liveDrag:true,
          gripInnerHtml:"<div class='grip'></div>", 
          draggingClass:"dragging", 
          minWidth:30
        }); 
        
      }); 
   </script>
   
<script src="resource/js/jQuery1.7.2.js"></script>

<script>
$(document).ready(function(e) {
	
	$("#id").change(function(){
		
		var checked=$(this).attr("checked");

		if(checked=="checked"){
			
			$(".check").attr("checked",true);
			
			}else{
				$(".check").attr("checked",false);
				}				
		});
	
    
});

</script>   

</head>

<body>

	<div class="metinfotop">
	<div class="position">简体中文：活动商品管理 > <a href="javascript:void(0)">活动商品列表</a></div>

	</div>
	<div class="clear"></div>


<div class="stat_list">
	<ul>
		<li class="now"><a href="index.php/admin/activity/list" title="活动商品列表">活动商品列表</a></li>
		<li ><a href="index.php/admin/activity/goodslist/status/1/aid/<?php echo ($aid); ?>" title="增加活动商品">增加活动商品</a></li>
	</ul>
</div>


<!-- 	<div id="button" class="mt10">
       <input type="button" name="button" class="btn btn82 btn_del" value="删除"> 
       <input type="button" name="button" class="btn btn82 btn_checked" value="全选"> 
       <input type="button" name="button" class="btn btn82 btn_nochecked" value="取消">   
     </div>-->
     
      <div id="search_bar" class="mt10">
       <div class="box">
          <div class="box_border">
            <div class="box_top"><b class="pl15">搜索</b></div>
            <div class="box_center pt10 pb10">
            <form action="" method="get">
              <table class="form_table" border="0" cellpadding="0" cellspacing="0">
              
                <tr>
                  <td>关键字</td>
                  <td><input type="text" name="keyword" class="input-text lh25" size="100"></td>
                  <td>状态</td>
                  <td>
                    <span class="fl">
                      <div class="select_border"> 
                        <div class="select_containers "> 
                        <select name="status" class="select">
                        	<option value="-1">---</option>  
                            <option value="1">审核</option> 
                            <option value="0">未审核</option> 
                        </select> 
                        </div> 
                      </div> 
                    </span>
                  </td>
                  <td><input type="submit" value="确定" class="ext_btn ext_btn_submit"></td>
                </tr>
               
              </table>
              </form>
            </div>
       
          </div>
        </div>
    </div>

<div id="table" class="mt10">
        <div class="box span10 oh">
        <form action="index.php/admin/activity/batchdel" method="post">
              <table width="100%" border="0" cellpadding="0" cellspacing="0" class="list_table">
                <tr>
                   <th width="100"><input  id="id" type="checkbox"  >ID</th>
                   <th width="150">商品名称</th>
                   <th width="150">商品编号</th>
                   <th width="80">商品原价</th>
                   <th width="80">活动类型</th>
                   <th width="80">优惠值</th>
                   <th width="80">活动价</th>
                   <th width="80">优惠数量</th>
                   <th width="80">已售数量</th>
                   <th width="80">商品库存</th>
                   <th width="60">状态</th>
                   <th width="120">操作</th>
                </tr>
                <tbody id="list">
                
                <?php if(is_array($list)): foreach($list as $k=>$vo): ?><tr class="tr">
                       <td class="td_center"><input type="checkbox" name="id[]" class="check" value="<?php echo ($vo["aid"]); ?>" ><?php echo ($vo["goodsid"]); ?></td>
                       <td align="center"><?php echo ($vo["gtitle"]); ?></td>
                       <td align="center"><?php echo ($vo["number"]); ?></td>
                       <td align="center"><?php echo ($vo["price"]); ?></td>
                       <td align="center"><?php echo ($vo["type"]); ?></td>
                       <td align="center"><?php echo ($vo["value"]); ?></td>
                       <td align="center"><?php echo ($vo["preferential"]); ?></td>
                       <td align="center"><?php echo ($vo["nums"]); ?></td>
                       <td align="center"><?php echo ($vo["sellnums"]); ?></td>
                       <td align="center"><?php echo ($vo["count"]); ?></td>                   
                       <td align="center"><img src="App/Admin/Common/images/checky_<?php echo ($vo["status"]); ?>.png" /></td>
                       <td align="center"><a href="index.php/admin/activity/delhdsp/id/<?php echo ($vo["id"]); ?>" onclick="return confirm('确定将此记录删除?')"><img src="App/Admin/Common/images/dele.png" alt="删除" /></a>&nbsp;&nbsp;<a href="index.php/admin/activity/dosave/id/<?php echo ($vo["id"]); ?>" onclick="return confirm('确定将此记录修改?')"><img src="App/Admin/Common/images/enid.png" alt="编辑" /></a>&nbsp;&nbsp;
                    
                       </td> 
                     </tr><?php endforeach; endif; ?>
                </tbody>
              	<tr>
                   <th colspan="12" align="left">
<!--                   		<input type="submit" name="checkall" id="id" class="btn btn82 btn_checked" value="全选">
                        <input type="submit" name="cancel"   id="cancel" class="btn btn82 btn_nochecked" value="取消">-->
                   		<input type="submit" name="del" class="btn btn82 btn_del" value="删除"> 
                        <input type="submit" name="status1" class="btn btn82 btn_del" value="启用"> 
                        <input type="submit" name="status0" class="btn btn82 btn_del" value="禁用">
                        <input type="button" name="button" class="btn btn82 btn_checked" value="全选"> 
       					<input type="button" name="button" class="btn btn82 btn_nochecked" value="取消">    
                   </th>
                </tr>
                
              </table>
              </form>
              <div class="page mt10">
                <div class="pagination">  
                 <ul><?php echo ($page); ?></ul>                           

                </div>

              </div>
        </div>
     </div>

</body>
</html>